
#
# Copyright © 2005-2010 Instigate CJSC, Armenia
#
# This library is free software; you can redistribute it and/or
# modify it under the terms of the GNU Lesser General Public
# License as published by the Free Software Foundation; either
# version 2.1 of the License, or (at your option) any later version.
#
# This library is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
# Lesser General Public License for more details.
#
# You should have received a copy of the GNU Lesser General Public
# License along with this library; if not, write to the Free
# Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
#
$(call check_variable,bin_dir)
$(call check_variable,lib_dir)
$(call check_variable,obj_dir)
$(call check_variable,inc_dir)
$(call check_variable,test_result_dir)
$(call check_variable,test_result)

t:=$(test_result) $(test_result_dir)
d:=$(bin_dir) $(lib_dir) $(obj_dir) $(inc_dir) $(t)

.PHONY: clean
clean: clean_docs clean_test 
	@echo -n "Cleaning up ... "
	@rm -rf $(d)
	@echo "done"

.PHONY: clean_test
clean_test:
	@echo -n "Cleaning up test-results ... "
	@rm -rf $(t)
	@echo "done"

.PHONY: clean_docs
clean_docs:
	@echo -n "Cleaning Doxygen generated files ... "
	@rm -rf $(doc_dir)
	@echo "done"
	
.PHONY: clean_user_docs
clean_user_docs:
	@echo -n "Cleaning user documents generated by Doxygen ... "
	@rm -rf $(usr_doc_dir)
	@echo "done"

.PHONY: clean_developer_docs
clean_developer_docs:
	@echo -n "Cleaning developer documents generated by Doxygen ... "
	@rm -rf $(dev_doc_dir)
	@echo "done"

.PHONY: clean_conf
clean_conf:
	@echo -n "Cleaning pkg configuration files ... "
	@rm -rf $(pkg_dir)
	@echo "done"

